package com.cykj.controller;

import com.cykj.dto.ResponseDto;
import com.cykj.service.MenuService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestParam;
import org.springframework.web.bind.annotation.RestController;

/**
 * @BelongsProject: Psychology
 * @BelongsPackage: com.cykj.controller
 * @Author: 小林
 * @CreateTime: 2025-01-17 15:40
 * @Description: 菜单
 * @Version: 1.0
 */
@RestController
@RequestMapping("/menu")
public class MenuController {
    @Autowired
    private MenuService menuService;


    /**
     * 获取所有菜单
     */
    @RequestMapping("/getAll")
    public ResponseDto getAll(@RequestParam("roleId") Long roleId){
        return menuService.getAll(roleId);
    }
}

